# Contributor: Justin Berthault <justin.berthault@zaclys.net>
# Maintainer: Justin Berthault <justin.berthault@zaclys.net>
pkgname=musescore
pkgver=3.6.2
pkgrel=3
pkgdesc="Create, play and print beautiful sheet music"
url="https://musescore.org/"
# armhf blocked by qt5-qtdeclarative
# s390x and riscv64 blocked by luatex -> texlive
arch="all !armhf !s390x !riscv64"
license="GPL-2.0-or-later"
depends="
	qt5-qtgraphicaleffects
	qt5-qtquickcontrols2
	"
install="$pkgname.pre-install $pkgname.pre-upgrade"
makedepends="
	ccache
	cmake
	doxygen
	jack-dev
	lame-dev
	libsndfile-dev
	portaudio-dev
	portmidi-dev
	pulseaudio-dev
	qt5-qtbase-dev
	qt5-qtquickcontrols2-dev
	qt5-qtdeclarative-dev
	qt5-qtscript-dev
	qt5-qtsvg-dev
	qt5-qttools-dev
	qt5-qtwebchannel-dev
	qt5-qtlocation-dev
	qt5-qtxmlpatterns-dev
	qtchooser
	"
source="$pkgname-$pkgver.tar.gz::https://github.com/musescore/MuseScore/archive/v$pkgver.tar.gz"
options="!check" # no testsuit provided
builddir="$srcdir"/MuseScore-$pkgver

build() {
	make PREFIX=/usr BUILD_WEBENGINE=OFF USE_SYSTEM_FREETYPE=ON revision release
}

package() {
	DESTDIR="$pkgdir" make UPDATE_CACHE=FALSE -C build.release install
}

sha512sums="04ff1ddd82358c070640f81bbaa9c47c5da95aa57c56a5d1b975ad984744e0def17d5581da6bbeda1aae1c68470100d104d4f8a39ba33bf37bf8891ffcbf1d6e  musescore-3.6.2.tar.gz"
